import request from '@/utils/request'
// 组织列表
export function listTissue(query) {
  return request({
    url: '/org/getlist',
    method: 'get',
    params: query
  })
}

// 组织树
export function parentlist(query) {
  return request({
    url: '/org/parentlist',
    method: 'get',
    params: query
  })
}

// 删除组织
export function deleteTissue(query) {
  return request({
    url: '/org/delete',
    method: 'get',
    params: query
  })
}

// 启用组织
export function openTissue(query) {
  return request({
    url: '/org/open',
    method: 'get',
    params: query
  })
}

// 新增组织
export function addTissue(data) {
  return request({
    url: '/org/add',
    method: 'post',
    data: data
  })
}

// 编辑组织
export function editTissue(data) {
  return request({
    url: '/org/edit',
    method: 'post',
    data: data
  })
}

// 换届列表
export function getyearlist(query) {
  return request({
    url: '/org/getyearlist',
    method: 'get',
    params: query
  })
}

// 班子成员列表
export function getteamlist(query) {
  return request({
    url: '/org/getteamlist',
    method: 'get',
    params: query
  })
}

// 新增换届
export function addtransyear(data) {
  return request({
    url: '/org/addtransyear',
    method: 'post',
    data: data
  })
}

// 删除换届
export function deleteTransYear(query) {
  return request({
    url: '/org/deletetransyear',
    method: 'get',
    params: query
  })
}

// 新增班子成员
export function addteamperson(data) {
  return request({
    url: '/org/addteamperson',
    method: 'post',
    data: data
  })
}

// 编辑班子成员
export function editteamperson(data) {
  return request({
    url: '/org/editteamperson',
    method: 'post',
    data: data
  })
}


// 删除班子成员
export function deleteteamperson(query) {
  return request({
    url: '/org/deleteteamperson',
    method: 'get',
    params: query
  })
}


// 上传班子成员照片
export function uploadteampic(data) {
  return request({
    url: '/fileupload/uploadteampic',
    method: 'post',
    data: data
  })
}
